//
//  ICBCBankCardOCR.h
//  ICBCBankCardOCR
//
//  Created by kfzx-tiansai on 2016/11/17.
//  Copyright © 2016年 icbc. All rights reserved.
//

#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>
#import <AVFoundation/AVFoundation.h>
#import <AudioToolbox/AudioToolbox.h>
#import <CoreMedia/CoreMedia.h>

@class ICBCBankCardOCR;
@protocol ICBCBankCardDelegate<NSObject>

@required
//银行卡识别核心初始化结果，判断核心是否初始化成功
- (void)initBankCardRecWithResult:(int)nInit;

//拍照和识别成功后返回结果图片、识别结果
- (void)cameraViewController:(ICBCBankCardOCR *)cameraVC resultImage:(UIImage *)image resultDictionary:(NSDictionary *)resultDic;

//获取银行卡全图
- (void)getFullResultImage:(UIImage *)image;

//返回按钮被点击时回调此方法，返回相机视图控制器
- (void)backWithCameraViewController:(ICBCBankCardOCR *)cameraVC;

//点击UIAlertView时返回相机视图控制器
- (void)clickAlertViewWithCameraViewController:(ICBCBankCardOCR *)cameraVC;

@optional
//相机视图将要显示时回调此方法，返回相机视图控制器
- (void)viewWillAppearWithCameraViewController:(ICBCBankCardOCR *)cameraVC;

//相机视图已经显示时回调此方法，返回相机视图控制器
- (void)viewDidAppearWithCameraViewController:(ICBCBankCardOCR *)cameraVC;

//相机视图将要消失时回调此方法，返回相机视图控制器
- (void)viewWillDisappearWithCameraViewController:(ICBCBankCardOCR *)cameraVC;

//相机视图已经消失时回调此方法，返回相机视图控制器
- (void)viewDidDisappearWithCameraViewController:(ICBCBankCardOCR *)cameraVC;

@end

@interface ICBCBankCardOCR : UIViewController
// isVertical YES:竖屏  NO:横屏
@property (assign,nonatomic) BOOL isVertical;

@property (assign,nonatomic) BOOL isHidePhotoButton;

@property(weak, nonatomic) id<ICBCBankCardDelegate> delegate;

@end

